# Maintainer: Pegah Bahramiani <pb.bahramiani@gmail.com>
pkgname=lua-resty-upload
pkgver=0.11
pkgrel=0
pkgdesc="Streaming reader and parser for HTTP file uploading based on ngx_lua cosocket"
url="https://github.com/openresty/lua-resty-upload"
# riscv64, ppc64le: no luajit
arch="all !riscv64 !ppc64le"
license="BSD-2-Clause"
depends="luajit"
source="https://github.com/openresty/lua-resty-upload/archive/v$pkgver/lua-resty-upload-$pkgver.tar.gz"
options="!check" # Test dependencies not available

package() {
	make install DESTDIR="$pkgdir" LUA_LIB_DIR="/usr/share/lua/5.1"

	echo 'rock_manifest = {}' > rock_manifest
	install -D -m 644 rock_manifest \
		"$pkgdir"/usr/lib/luarocks/rocks-5.1/$pkgname/$pkgver-1
}
sha512sums="
4aa778701dd869524cc448ae62af2efdc633215806326e8bcda094cdd7e71d4e362948412d46c5121c41c01891fa369d7d55dc67c11e1db65ea6e5e074b733ba  lua-resty-upload-0.11.tar.gz
"
